package org.dtrd.modules.food.entity.bean;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.dtrd.modules.food.entity.po.DtrdExtEmsYwRecipes;

import java.util.Date;

/**
 * @author qr
 * @date 2021/12/8 18:08
 */
@ApiModel("食谱列表信息")
@Getter
@Setter
public class RecipeListInfo {

    private Integer id;

    @ApiModelProperty("食谱名称")
    private String recipeName;

    @ApiModelProperty("食谱照片")
    private String recipePhoto;

    @ApiModelProperty("热量")
    private Integer kcal;

    private String label;

    @ApiModelProperty("创建时间")
    private Date createTime;

    public RecipeListInfo(DtrdExtEmsYwRecipes po){
        id = po.getDataId();
        recipeName = po.getRecipeName();
        recipePhoto = po.getRecipeThumb();
        kcal = po.getRecipeKcal();
        createTime = po.getRecipeCreateTime();
        label = po.getRecipeTips();
    }
}
